<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>编辑工作计划</title>
<link rel="stylesheet" href="__PUBLIC__/lib/bootstrap/css/bootstrap.min.css">
<script src="__PUBLIC__/lib/bootstrap/js/jquery.min.js"></script>
<script src="__PUBLIC__/lib/bootstrap/js/bootstrap.min.js"></script>
<script src="__PUBLIC__/lib/My97DatePicker/WdatePicker.js" type='text/javascript'></script>
<script src="__PUBLIC__/lib/layer/layer.js" type='text/javascript'></script>
<style type="text/css">
	.td_index{	width: 10%; }
	.td_workplan{	width: 40%; }
	.td_progress{	width: 10%; }
	.td_pprogress{	width: 10%; }
	.td_plancompletedata{	width: 10%; }
	.td_date{	width: 10%; }
	.td_delete{	width: 10%; }
</style>
</head>
<body>
<form action="__APP__/Home/Index/modifyWorkPlan" method="post" class="form-inline" role="form" >
	<table style="width:100%; height:100%; margin:0 auto; " class="table  table-striped table-bordered table-condensed text-center" >
		<tr>
			<td class="td_index"><span class="btn btn-default" role="button" id="tips_idnum">序号</span></td>
			<td class="td_workplan"><span class="btn btn-default" role="button" id="tips_workplan">工作计划</span></td>
			<td class="td_progress"><span class="btn btn-default" role="button" id="tips_nowprogress">目前进度</span></td>
			<td class="td_pprogress"><span class="btn btn-default" role="button" id="tips_dateprogress">今日完成进度</span></td>
			<td class="td_plancompletedata"><span class="btn btn-default" role="button">预计完成日期</span></td>
			<td class="td_date"><span class="btn btn-default" role="button">日期</span></td>
			<td class="td_delete"><span class="btn btn-default" role="button" id="tips_deletet">删除</span></td>
		</tr>
		<volist name="planlist" id="vo">
			<tr>
				<td class="td_index" style="vertical-align: middle;">
					<span class="btn btn-success">{$key+1}</span>
					<input type="hidden" name="id_{$key+1}" value="{$vo.id}" >
				</td>
				<td class="td_workplan" style="vertical-align: middle;">
					<textarea name="plan_{$key+1}" class="form-control" style="width: 100%;"  rows="2">{$vo.plan}</textarea>
				</td>
				<td class="td_progress" style="vertical-align: middle;">
					<input type="text" name="progress_{$key+1}" class="form-control" style="width: 80%;" value="{$vo.progress}"><span>%</span>
				</td>
				<td class="td_pprogress" style="vertical-align: middle;">
					<input type="text" name="pprogress_{$key+1}" class="form-control" style="width: 80%;" value="{$vo.pprogress}"><span>%</span>
				</td>
				<td class="td_plancompletedata" style="vertical-align: middle;">
					<input type="text" name="pcdate_{$key+1}" class="form-control" style="width: 100%;"  onclick="WdatePicker({isShowWeek:true,dateFmt:'yyyy-MM-dd'})"  value="{$vo.cdate}">
				</td>
				<td class="td_date" style="vertical-align: middle;">
					<input type="text" name="date_{$key+1}"  value="{$vo.date}"class="form-control"   readonly >
				</td>
				<td class="td_delete"  style="vertical-align: middle;">
					<input type="checkbox"  name="delete_{$key+1}" >
				</td>
			</tr>
		</volist>
		
		<for start="$item.start" end="$item.end">
			<tr>
				<td class="td_index" style="vertical-align: middle;"><span  class="btn btn-default">{$i}</span></td>
				<td class="td_workplan">
					<textarea name="plan_{$i}" class="form-control"  style="width: 100%;" rows="2"></textarea>
				</td>
				<td class="td_progress" style="vertical-align: middle;">
					<input type="text" name="progress_{$i}" class="form-control" style="width: 80%;" value="0"><span>%</span>
				</td>
				<td class="td_pprogress" style="vertical-align: middle;">
					<input type="text" name="pprogress_{$i}" class="form-control" style="width: 80%;" value="100"><span>%</span>
				</td>
				<td class="td_plancompletedata" style="vertical-align: middle;">
					<input type="text" name="pcdate_{$i}" class="form-control" style="width: 100%;"  onclick="WdatePicker({isShowWeek:true,dateFmt:'yyyy-MM-dd'})" value="{$item.date}">
				</td>
				<td class="td_date" style="vertical-align: middle;">
					<input type="text" name="date_{$i}" value="{$item.date}" class="form-control" readonly  >
				</td>
				<td class="td_delete"  style="vertical-align: middle;">
					<input type="checkbox"  name="delete_{$i}" disabled="disabled">
				</td>
			</tr>
		</for>
		
		<tr>
			<td colspan="7">
				<input type="hidden" value="{$item.end}" name="num" >
				<input class="btn btn-default" type="submit" value="Submit">
			</td>
		</tr>
	</table>
</form>
<script type="text/javascript">
	layer.use('extend/layer.ext.js'); //载入layer拓展模块
	$(document).ready(function() {

		$("#tips_deletet").hover(function() {
			layer.tips('勾选后将删除该条计划记录', '#tips_deletet',{tips: [2, '#78BA32']});
		}, function() {
		});
		
		$("#tips_idnum").hover(function() {
			layer.tips('绿色为今天已经添加计划，白色为空白的新计划', '#tips_idnum',{tips: [2, '#78BA32']});
		}, function() {
		});
		
		$("#tips_workplan").hover(function() {
			layer.tips('工作计划不为空的时候，提交则会添加新纪录', '#tips_workplan',{tips: [2, '#78BA32']});
		}, function() {
		});
		
		$("#tips_nowprogress").hover(function() {
			layer.tips('这个计划昨天的完成进度，如果是新计划，请写0%', '#tips_nowprogress',{tips: [3, '#78BA32']});
		}, function() {
		});
		
		$("#tips_dateprogress").hover(function() {
			layer.tips('这个计划今天预计完成的进度，晚上改为实际完成进度', '#tips_dateprogress',{tips: [3, '#78BA32']});
		}, function() {
		});
		

	});
</script>
</body>
</html>
